package com.cisc.business.user.service.impl;

import com.cisc.business.user.dao.UserMapper;
import com.cisc.business.user.dto.UserInfo;
import com.cisc.business.user.service.UserService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * @description: XXX
 * @author: daizh
 * @time: 2021/6/20 8:14
 */
@Service
public class UserServiceImpl implements UserService {

    @Resource
    private UserMapper userMapper;

    @Override
    public UserInfo getUserById(Integer userid) {
        return userMapper.getUserById(userid);
    }

    @Override
    public List<UserInfo> getUserByName(String username) {
        return userMapper.getUserByName(username);
    }

    @Override
    public List<UserInfo> getAllUsers() {
        return userMapper.getAllUsers();
    }

    @Override
    public void saveUserInfo(UserInfo userInfo) {
        userMapper.saveUserInfo(userInfo);
    }
}
